package cn.demengsite.dao;

import cn.demengsite.model.Member;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface MemberDAO  {
    List<Member> getAllMember();

    Member getMemberByMobile(String mobile);

    Member getMemberByCard(String cardId);

    int addNewMember(Member member);

    int updateMember(Member member);

    int memberRecharge(@Param("rechargeValue") Double rechargeValue, @Param("id") Integer id);

    int memberGainScores(@Param("score") Double score, @Param("id") Integer id);

    List<Member> getMemberByCreateTime(@Param("beginTime") String begin,@Param("endTime") String end);

}
